/*
 * 文件名：ProductServiceImpl.java
 * 版权：
 * 描述：TODO
 * 修改人：zuo liubo
 * 修改时间：2013-1-30 上午11:23:02
 */
package com.scpii.api.service.ec.impl;

import java.util.List;

import javax.annotation.Resource;

import org.springframework.stereotype.Service;

import com.scpii.api.domain.ec.Product;
import com.scpii.api.persistence.ec.ProductMapper;
import com.scpii.api.service.ec.ProductService;

/**
 * @description TODO
 * @author zuo liubo
 * @date 2013-1-30
 */
@Service("productService")
public class ProductServiceImpl implements ProductService {

	@Resource
	private ProductMapper productsMapper;
	
	@Override
	public List<Product> getProductsByCatId(Product product) {
		product.setPublish(1);
		return productsMapper.selectBySelective(product);
	}

	@Override
	public List<Product> searchProduct(Product product) {
		return productsMapper.searchProduct(product);
	}

}
